package cn.edu.lcu.cs.javaprogramming.oop.animal;

import lombok.Data;

/**
 * 鱼类，抽象类，不能实例化。
 *
 * @author: ling
 * @since: 2022-03-11 16:07
 **/
public abstract class Fish extends Animal implements Swimmable {
    public Fish() {
        setSpeciesName("鱼类");
    }

    @Override
    public void swim() {
        System.out.println(getSpeciesName() + "都会游泳");
    }

    @Override
    public void breath() {
        System.out.println(getSpeciesName() + "用鳃呼吸");
    }

}
